﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DotNet
{
    public class Func
    {
        public void Lamda()
        {
            Func<int, string> lamda = x =>
                                      {
                                          var tmp = x;
                                          return tmp.ToString();
                                      };

            Func<int, Func<int, string>> lamdaComplex = x =>
                                                        {
                                                            return name =>
                                                                   {
                                                                       var tmp = name.ToString();
                                                                       return tmp;
                                                                   };
                                                        };

            Console.WriteLine(lamda(123));
            Console.WriteLine(lamdaComplex(123).Invoke(456));
        }
    }
}
